package com.testnetty;
import com.testnetty.commot.NettyServer;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class QhNeetyApplication implements CommandLineRunner {
    public static void main(String[] args) {
        SpringApplication.run(QhNeetyApplication.class, args);
    }

    @Override
    public void run(String... args) throws Exception {
        new Thread(()->{
            try {
                new NettyServer(8000).run();
            } catch (Exception e) {
                e.printStackTrace();
            }
        }).start();
    }
}

